-- GENERATED SPELL FOR [Skeletal Healer] --


function spell0_787(pUnit, Event) --@Heal,Heal--
pUnit:FullCastSpellOnTarget(2054,pUnit)
pUnit:RegisterEvent('Sorts_787', 3000, 1)
end

function spell1_787(pUnit, Event) --@Shadow Bolt,n/a--
pUnit:FullCastSpellOnTarget(9613,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_787', 3000, 1)
end

function Sorts_787(pUnit, Event)
local choix_sorts_787 = math.random(0, 1)
if choix_sorts_787 == 0 then
pUnit:RegisterEvent('spell0_787', 1, 1)
end
if choix_sorts_787 == 1 then
pUnit:RegisterEvent('spell1_787', 1, 1)
end
end

function mob787_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_787', math.random(1500, 3000), 1)
end

function mob787_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob787_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob787_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(787, 1, 'mob787_Action')
RegisterUnitEvent(787, 2, 'mob787_Leave')
RegisterUnitEvent(787, 3, 'mob787_Kill')
RegisterUnitEvent(787, 4, 'mob787_Die')
